---@diagnostic disable: undefined-global
rednet.open("right")

if rednet.isOpen("right") then
    print("rednet is OK!\n")
end
local num
while rednet.isOpen("right") do
    repeat sleep(0.05) until num ~=redstone.getAnalogInput("front")
    rednet.send(65,("%d"):format(redstone.getAnalogInput("front")))    
    num =redstone.getAnalogInput("front")
    print("%s"):format(redstone.getAnalogInput("front"))
    sleep(0.1)
end
  



